import request from "@/utils/axios";
import { URL_API } from "@/utils/mUtils";
const base = URL_API();
//创建计费产品
export function BillingRuleCreateFn(params) {
  return request({
    url: `${base}/api/billing_rule/create`,
    method: "post",
    data: params,
  });
}
// 计费规则列表
export function BillingRuleListFn(params) {
  return request({
    url: `${base}/api/billing_rule/list`,
    method: "post",
    data: params,
  });
}
// 删除计费规则
export function BillingRuleDeleteFn(params) {
  return request({
    url: `${base}/api/billing_rule/delete`,
    method: "DELETE",
    data: params,
  });
}
// 删除计费规则
export function BillingRuleDetailFn(params) {
  return request({
    url: `${base}/api/billing_rule/detail`,
    method: "POST",
    data: params,
  });
}
// 修改计费规则
export function BillingRuleUpdateFn(params) {
  return request({
    url: `${base}/api/billing_rule/update`,
    method: "PUT",
    data: params,
  });
}
// 导入计费规则
export function BillingRuleImportFn(params) {
  return request({
    url: `${base}/api/billing_rule/import`,
    method: "POST",
    data: params,
  });
}
// 导出计费规则
export function BillingRuleExportFn(params) {
  return request({
    url: `${base}/api/billing_rule/export`,
    method: "POST",
    data: params,
  });
}

// 计费规则阶梯区间list
export function BillingRulePriceListFn(params) {
  return request({
    url: `${base}/api/billing_rule/regional_range_price/list`,
    method: "POST",
    data: params,
  });
}
// 计费规则阶梯区间Add
export function BillingRulePriceAddFn(params) {
  return request({
    url: `${base}/api/billing_rule/regional_range_price/create`,
    method: "POST",
    data: params,
  });
}
// 计费规则阶梯区间edit
export function BillingRulePriceUpdateFn(params) {
  return request({
    url: `${base}/api/billing_rule/regional_range_price/update`,
    method: "PUT",
    data: params,
  });
}
// 计费规则阶梯区间delete
export function BillingRulePriceDeleteFn(params) {
  return request({
    url: `${base}/api/billing_rule/regional_range_price/delete`,
    method: "DELETE",
    data: params,
  });
}
// 计费规则区间add
export function BillingRuleRangeCreate(params) {
  return request({
    url: `${base}/api/billing_rule/range/create`,
    method: "POST",
    data: params,
  });
}
// 计费规则区间delete
export function BillingRuleRangeDelete(params) {
  return request({
    url: `${base}/api/billing_rule/range/delete`,
    method: "DELETE",
    data: params,
  });
}
// 计费规则区间update
export function BillingRuleRangeUpdate(params) {
  return request({
    url: `${base}/api/billing_rule/range/update`,
    method: "PUT",
    data: params,
  });
}
// 默认负责人列表
export function ResponsibleList(params) {
  return request({
    url: `${base}/api/branch/default/responsible/person/list`,
    method: "POST",
    data: params,
  });
}
// 默认负责人add
export function ResponsibleAdd(params) {
  return request({
    url: `${base}/api/branch/default/responsible/person/create`,
    method: "POST",
    data: params,
  });
}
// 默认负责人update
export function ResponsibleUpdate(params) {
  return request({
    url: `${base}/api/branch/default/responsible/person/update`,
    method: "PUT",
    data: params,
  });
}
// 默认负责人del
export function ResponsibleDelete(params) {
  return request({
    url: `${base}/api/branch/default/responsible/person/delete`,
    method: "DELETE",
    data: params,
  });
}
// 消息规则列表
export function reqMessageRulesList(params) {
  return request({
    url: `${base}/api/message_rule/list`,
    method: "POST",
    data: params,
  });
}
// 新增消息规则
export function reqMessageRulesCreate(params) {
  return request({
    url: `${base}/api/message_rule/create`,
    method: "POST",
    data: params,
  });
}
// 消息规则详情
export function reqMessageRulesDetail(params) {
  return request({
    url: `${base}/api/message_rule/detail`,
    method: "POST",
    data: params,
  });
}
// 编辑消息规则
export function reqMessageRulesUpdate(params) {
  return request({
    url: `${base}/api/message_rule/update`,
    method: "POST",
    data: params,
  });
}
// 消息规则更新状态
export function reqMessageRulesStatus(params) {
  return request({
    url: `${base}/api/message_rule/update_status`,
    method: "POST",
    data: params,
  });
}
// 导入文件字段匹配
export function dataFieldMapping(params) {
  return request({
    url: `${base}/api/data/migration/field/mapping`,
    method: "POST",
    data: params,
  });
}
// 导入数据
export function dataFieldImport(params) {
  return request({
    url: `${base}/api/data/migration/data/import`,
    method: "POST",
    data: params,
  });
}
// 区域客服列表
export function BranchServiceList(params) {
  return request({
    url: `${base}/api/branch/customer/service/list`,
    method: "POST",
    data: params,
  });
}
// 修改区域客服电话
export function BranchServiceUpdate(params) {
  return request({
    url: `${base}/api/branch/customer/service/update`,
    method: "POST",
    data: params,
  });
}